package com.example.lc.mythreedemo;

import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import com.example.lc.mythreedemo.custom.MyGridView;

import java.util.List;

/**
 * 名片模版选择界面
 *
 * @author: lc
 * @data: 2016/10/18 10:57
 * Created by  2016 广州聚酷软件科技有限公司 All Right Reserved
 */

public class SelectNameCardTemplateFragment extends Fragment {

    private MyGridView gv_name_card_template;
    private SelectNameCardTemplateAdapter selectnamecardtemplateadapter;
    private SelectNameCardTemplateAdapterTwo selectnamecardtemplateadaptertwo;
    private static List<EnterpriseHomeEntity> dataList;

    public static SelectNameCardTemplateFragment newInstance(List<EnterpriseHomeEntity> list) {
        dataList = list;
        SelectNameCardTemplateFragment fragment = new SelectNameCardTemplateFragment();
        return fragment;
    }

    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
    }

    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
        View view =
                inflater.inflate(R.layout.fragment_select_name_card_template, container, false);
        gv_name_card_template = (MyGridView) view.findViewById(R.id.gv_all_name_card);
        selectnamecardtemplateadapter = new SelectNameCardTemplateAdapter(getActivity(), dataList);
        gv_name_card_template.setAdapter(selectnamecardtemplateadapter);
        return view;
    }

}
